.project-detail-page {
  padding-bottom: 80px;
}

.loading-container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 60vh;
}

.loader {
  border: 5px solid #f3f3f3;
  border-top: 5px solid var(--primary-color);
  border-radius: 50%;
  width: 50px;
  height: 50px;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.error-container {
  text-align: center;
  padding: 100px 0;
}

.error-container h2 {
  font-size: 2rem;
  margin-bottom: 20px;
}

.error-container p {
  margin-bottom: 30px;
  color: var(--light-text-color);
}

.project-header {
  text-align: center;
  margin-bottom: 40px;
}

.project-title {
  font-size: 2.5rem;
  margin-bottom: 20px;
}

.project-tags {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
}

.project-tag {
  padding: 5px 15px;
  background-color: rgba(37, 99, 235, 0.1);
  color: var(--primary-color);
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 500;
}

.project-showcase {
  margin-bottom: 50px;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.project-main-image {
  width: 100%;
  height: auto;
  display: block;
}

.project-content-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 40px;
  margin-bottom: 50px;
}

.project-description h2 {
  font-size: 1.8rem;
  margin-bottom: 20px;
  color: var(--text-color);
}

.project-description p {
  margin-bottom: 20px;
  color: var(--light-text-color);
  line-height: 1.7;
}

.project-long-description {
  color: var(--light-text-color);
  line-height: 1.7;
}

.project-long-description h2,
.project-long-description h3 {
  margin-top: 30px;
  margin-bottom: 15px;
  color: var(--text-color);
}

.project-long-description ul,
.project-long-description ol {
  margin-bottom: 20px;
  padding-left: 20px;
}

.project-long-description li {
  margin-bottom: 10px;
}

.details-card {
  background-color: #f8fafc;
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.details-card h3 {
  font-size: 1.3rem;
  margin-bottom: 20px;
  color: var(--text-color);
}

.detail-item {
  display: flex;
  justify-content: space-between;
  padding: 15px 0;
  border-bottom: 1px solid var(--border-color);
}

.detail-item:last-child {
  border-bottom: none;
}

.detail-label {
  font-weight: 500;
  color: var(--text-color);
}

.detail-value {
  color: var(--light-text-color);
}

.detail-link {
  color: var(--primary-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

.detail-link:hover {
  color: var(--secondary-color);
}

.project-gallery {
  margin-bottom: 50px;
}

.project-gallery h2 {
  font-size: 1.8rem;
  margin-bottom: 30px;
  color: var(--text-color);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}

.gallery-item {
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease;
}

.gallery-item:hover {
  transform: translateY(-5px);
}

.gallery-item img {
  width: 100%;
  height: auto;
  display: block;
}

.related-projects {
  margin-bottom: 50px;
}

.related-projects h2 {
  font-size: 1.8rem;
  margin-bottom: 30px;
  color: var(--text-color);
}

.related-projects-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.related-project-card {
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease;
}

.related-project-card:hover {
  transform: translateY(-10px);
}

.related-project-image {
  position: relative;
  height: 200px;
  overflow: hidden;
}

.related-project-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.related-project-card:hover .related-project-image img {
  transform: scale(1.05);
}

.related-project-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.related-project-card:hover .related-project-overlay {
  opacity: 1;
}

.related-project-link {
  padding: 8px 15px;
  background-color: var(--primary-color);
  color: white;
  border-radius: 4px;
  font-size: 0.9rem;
  transition: background-color 0.3s ease;
}

.related-project-link:hover {
  background-color: var(--secondary-color);
}

.related-project-title {
  padding: 15px;
  font-size: 1.1rem;
  text-align: center;
}

.project-navigation {
  display: flex;
  justify-content: center;
  margin-top: 50px;
}

.back-to-portfolio {
  display: inline-block;
  padding: 10px 20px;
  background-color: var(--primary-color);
  color: white;
  border-radius: 5px;
  text-decoration: none;
  transition: background-color 0.3s ease;
}

.back-to-portfolio:hover {
  background-color: var(--secondary-color);
}

@media (max-width: 992px) {
  .project-content-grid {
    grid-template-columns: 1fr;
  }
  
  .related-projects-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .project-detail-page {
    padding-bottom: 60px;
  }
  
  .project-title {
    font-size: 2rem;
  }
  
  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  }
  
  .related-projects-grid {
    grid-template-columns: 1fr;
  }
}
